import requests

res = requests.post('https://www.xiaomiyoupin.com/mtop/market/search/v2/doSearch',json=
{
    "query": [
        {
            "queryName": "智能家居",
            "queryType": 0,
            "rule": []
        }
    ],
    "sortBy": 0,
    "pageIdx": 20,
    "strategyInfo": "",
    "filter": "",
    "baseParam": {
        "imei": "",
        "clientVersion": "",
        "ypClient": 3
    },
    "source": "searchPage",
    "requestId": "11612179530488165",
    "clientPageId": "6713521646529518",
    "recentAddress": "",
    "requestExtraInfo": {},
    "pageSize": 20
},
    headers=  {
        "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36",
        "Content-Type": "application/json;charset=UTF-8",
        "cookie":"youpindistinct_id=19aa69515a1102-0b42bd32dc2f3-26061b51; mjclient=PC; Hm_lvt_025702dcecee57b18ed6fb366754c1b8=1763731380; HMACCOUNT=9DDF9DE41629DB76; youpin_sessionid=19aa6a798fd-0c35ffc4fe52d68-1fa8; Hm_lpvt_025702dcecee57b18ed6fb366754c1b8=1763732593"
            } ,
 )
# {"query":[{"queryName":"智能家居","queryType":0,"rule":[]}],"sortBy":0,"pageIdx":20,"strategyInfo":null,"filter":null,"baseParam":{"imei":"","clientVersion":"","ypClient":3},"source":"searchPage","requestId":"11612179530488165","clientPageId":"6713521646529518","recentAddress":null,"requestExtraInfo":{},"pageSize":20}



print(res.json())